package xju_9_10.springboot_9_10.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.time.LocalDateTime;

@Data
@TableName("`user`") // 指定表的名称
public class User {
//    @TableId(type = IdType.ASSIGN_ID)
    private Long id;
    private String name;
    private Integer age;
    private String email;

    // 自动填充
    @TableField(fill = FieldFill.INSERT)  // 添加时 进行填充
    private String  createTime;
    @TableField(fill = FieldFill.INSERT_UPDATE) // 添加和更新时 进行填充
    private String updateTime;

    // 逻辑删除
//    @TableLogic
    private Boolean deleted;
}
